import { defineConfig } from 'umi';
export default defineConfig({
  hash: true,
  history: {
    type: 'hash',
  },
  routes: [
    {
      exact: true,
      path: '/login',
      component: '@/pages/Login',
      title: '登录',
    },
    {
      exact: true,
      path: '/register',
      component: '@/pages/Register',
      title: '注册',
    },
    {
      exact: true,
      path: '/forgetpwd',
      component: '@/pages/ForgetPwd',
      title: '忘记密码',
    },
    {
      exact: true,
      path: '/404',
      component: '@/pages/404',
      title: '页面未找到',
    },
    {
      exact: false,
      path: '/',
      component: '@/layout/SecurityLayout',
      routes: [
        {
          exact: false,
          path: '/',
          component: '@/layout/BaseLayout',
          routes: [
            {
              exact: true,
              path: '/',
              component: '@/pages/Home',
              title: '主页',
            },
            {
              exact: false,
              path: '/*',
              component: '@/pages/404',
              title: '页面未找到',
            },
          ],
        },
      ],
    },
  ],
});
